<template>
  <div class="home">
    <div v-html="name"></div>
    <div v-show="isshow">来打我吧</div>
    <button @click="choose">点击我吧</button>
    <button @click="choose1">点击我吧</button>
  </div>
</template>

<script>
import HelloWorld from "@/components/HelloWorld.vue";

export default {
  name: "Home",
  //变量仓库woaki
  data() {
    return {
      name: "lth",
      isshow: false,
    };
  },
  components: {
    HelloWorld,
  },
  //方法库
  methods: {
    choose() {
      this.name = "<h1>小红</h1>";
    },
    choose1() {
      this.isshow = true;
    },
  },
};
</script>
<style>
body,
html {
  cursor: pointer;
}
</style>
